import time
import sched
import os
schedule = sched.scheduler( time.time,time.sleep)

def retail():
    os.system("echo 'info all' |  /home/oracle/oggforbigdata/ggsci | grep MANAGER");
    # os.system("java -jar datacompare-1.0-SNAPSHOT.jar -dbtype oracle -dbname yhspeas -username c##ggadmin -password ggadmin123  -filename yhspbi  -shema yhsp -host  localhost  -port 1521")
# 周期
def perform(inc):
    schedule.enter(inc, 0, perform, (inc,))
    retail()


print("start")
# schedule.enter(16800,0,retail,())
schedule.enter(0, 0, perform, (3,))
schedule.run()
print("end")